<?php
namespace Admin\Controller;
class MessageController extends BaseController {
    public function index(){

        $arr=M('Message')->select();
        $count = M('Message')->count();
        $this->assign('count',$count);
        $this->assign('arr',$arr);
        $this->display();
    }
    //删除
    public function del(){
       $res=M('Message')->where($_POST)->delete();
       if($res){
        $this->ajaxReturn(1);
       }else{
        $this->ajaxReturn(0);
       }
    }
}